<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title></title>
<link type="text/css" rel="stylesheet" href="../css/style.css" />
<script src="../js/AC_RunActiveContent.js" type="text/javascript"></script>
<script language="javascript"> 
function checkname(){ 
var div = document.getElementById("div1"); 
div.innerHTML = ""; 
var name1 = document.form1.text1.value; 
if (name1 == "") { 
div.innerHTML = "姓名不能为空！"; 
document.form1.text1.focus(); 
return false; 
} 
if (name1.length < 4 || name1.length > 16) { 
div.innerHTML = "姓名输入的长度4-16个字符！"; 
document.form1.text1.select(); 
return false; 
} 
var charname1 = name1.toLowerCase(); 
for (var i = 0; i < name1.length; i++) { 
var charname = charname1.charAt(i); 
if (!(charname >= 0 && charname <= 9) && (!(charname >= 'a' && charname <= 'z')) && (charname != '_')) { 
div.innerHTML = "姓名包含非法字母，只能包含字母，数字，和下划线"; 
document.form1.text1.select(); 
return false; 
} 
} 
return true;

}

function checkpassword(){ 
var div = document.getElementById("div2"); 
div.innerHTML = ""; 
var password = document.form1.text2.value; 
if (password == "") { 
div.innerHTML = "密码不位空！"; 
document.form1.text2.focus(); 
return false; 
} 
if (password.length < 4 || password.length > 12) { 
div.innerHTML = "密码长度4-12位"; 
document.form1.text2.select(); 
return false; 
} 
return true; 
}

function checkrepassword(){ 
var div = document.getElementById("div3"); 
div.innerHTML = ""; 
var password = document.form1.text2.value; 
var repass = document.form1.text3.value; 
if (repass == "") { 
div.innerHTML = "密码不位空！"; 
document.form1.text3.focus(); 
return false; 
} 
if (password != repass) { 
div.innerHTML = "输入密码和确认密码长度不一致"; 
document.form1.text3.select(); 
return false; 
} 
return true; 
}

function checkEmail(){ 
var div = document.getElementById("div4"); 
div.innerHTML = ""; 
var email = document.form1.text5.value; 
var sw = email.indexOf("@", 0); 
var sw1 = email.indexOf(".", 0); 
var tt = sw1 - sw; 
if (email.length == 0) { 
div.innerHTML = "电子邮件不能位空"; 
document.form1.text5.focus(); 
return false; 
} 
if (email.indexOf("@", 0) == -1) { 
div.innerHTML = "电子邮件格式不正确，必须包含@符号！"; 
document.form1.text5.select(); 
return false; 
} 
if (email.indexOf(".", 0) == -1) { 
div.innerHTML = "电子邮件格式不正确，必须包含.符号!"; 
document.form1.text5.select(); 
return false; 
} 
if (tt == 1) { 
div.innerHTML = "邮件格式不对。@和.不可以挨着！"; 
document.form1.text5.select(); 
return false; 
} 
if (sw > sw1) { 
div.innerHTML = "电子邮件格式不正确，@符号必须在.之前"; 
document.form1.text5.select(); 
return false; 
} 
else { 
return true; 
}

return ture; 
}

function check(){ 
if (checkname() && checkpassword() && checkrepassword() && checkEmail()) { 
return true; 
} 
else { 
return false; 
} 
} 
</script>
</head>

<body>
<!--顶部开始-->
<div class="top">
<div class="top_bg">
<div class="top_1"><span><a href="zc.html">注册</a>|<a href="dl.html">登陆</a></span></div>
<div class="clear"></div>
<!--logo开始-->
<div class="logo">
<h1><a href="index.html"></a></h1>
</div>
<!--logo结束-->
<!-- 导航开始 -->
<div class="menu">
<ul>
<li><a href="index.html" id="on">网站首页</a></li>
<li><a href="zsgc.html">电影管理</a></li>
<li><a href="products.html">人物介绍</a></li>
<li><a href="products2.html">连载动漫</a></li>
<li><a href="products1.html">logo合集</a></li>
<li><a href="products3.html">最近新闻</a></li>
<li><a href="products4.html">人物周边</a></li>
</ul>
</div>
<!-- 导航结束 -->
</div>
</div>
<!--顶部结束-->
<img src="../images/2.2.jpg" width="980" height="455" style="margin:0 auto; display:block;" />
<!--中部开始-->
<div class="main_1">
<div class="banner">
  <div class="gun">
<ul>
<li><img src="../images/images_1/M1.jpg" alt="1" width="240" height="153"/><li>
<li><img src="../images/images_1/M3.jpg" alt="2" width="232" height="152"/></li>
<li> <img src="../images/images_1/M5.jpg" alt="4" width="242" height="154"/></li>
<li><img src="../images/images_1/M6.jpg" alt="3" width="230" height="153"/></li>
</ul>
</div>
</div>
<div class="main_1_contact">
<img src="../images/10years.jpg" width="182" height="122" alt="contact" />
</div>
<div class="main_1_right"><p><form name="form1" method="post" action="2.html" onsubmit="return check()"> 
<table width="477" height="106"> 
<tr> 
<td width="156" style="color: #FFFFFF"> 
用户名： 
</td> 
<td width="309"> 
<input id="text1" type="text" name="text1" onblur="check()"> 
<div id="div1" style="display:inline"> 
</div> 
</td> 
</tr> 
<tr> 
<td style="color: #FFFFFF"> 
密码： 
</td> 
<td> 
<input id="text2" type="password" name="text2" onblur="check()"> 
<div id="div2" style="display:inline"> 
</div> 
</td> 
</tr> 
<tr> 
<td style="color: #FFFFFF"> 
确认密码： 
</td> 
<td> 
<input id="text3" type="password" name="text3" onblur="check()"> 
<div id="div3" style="display:inline"> 
</div> 
</td> 
</tr> 
<tr> 
<td style="color: #FFFFFF"> 
电子邮件： 
</td> 
<td> 
<input id="text4" type="text" name="text4" onblur="check()"> 
<div id="div4" style="display:inline"> 
</div> 
</td> 
</tr> 
<tr align="center"> 
<td align="center"> 
<input type="submit" value="提交" name="tect6"><input type="reset" value="重置" name="text7"> 
</td> 
</tr> 
</table> </form>
</p>
</div>

</div>
<!--中部结束-->



<!--底部开始-->
<div class="footer">
<div class="bottom">

<div class="bottom_logo">
<p>版权所有 · 梦工厂</p>
</div>

</div>
</div>
<!--底部结束-->

</body>
</html>
